# from src.plugins import PluginManager
#
# print(PluginManager().exec_plugin())
import os
from gevent import monkey;

monkey.patch_all()
import gevent

this_path = os.getcwd()
desc_path = 'D:\PythonProject\Agen'


def func(i):
    with open('hostname/host_name.txt', 'w', encoding='utf-8') as f:
        name = 'ceshi' + str(i)
        f.write(name)
    os.system(r'python .\bin\start.py')
    print(i)


a_list = []
for i in range(1, 100):
    j = gevent.spawn(func, i)

gevent.joinall(a_list)